package com.zz.parkingsystem.entity;

import java.io.Serializable;
import java.math.BigDecimal;
import lombok.Data;

/**
 * 支付统计表
 * @TableName t_pay_count
 */
@Data
public class PayCount implements Serializable {
    /**
     * 支付统计编号
     */
    private Integer pcId;

    /**
     * 微信支付金额
     */
    private BigDecimal pcWechatAmount;

    /**
     * 支付宝支付金额
     */
    private BigDecimal pcAliAmount;

    private static final long serialVersionUID = 1L;

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        PayCount other = (PayCount) that;
        return (this.getPcId() == null ? other.getPcId() == null : this.getPcId().equals(other.getPcId()))
            && (this.getPcWechatAmount() == null ? other.getPcWechatAmount() == null : this.getPcWechatAmount().equals(other.getPcWechatAmount()))
            && (this.getPcAliAmount() == null ? other.getPcAliAmount() == null : this.getPcAliAmount().equals(other.getPcAliAmount()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getPcId() == null) ? 0 : getPcId().hashCode());
        result = prime * result + ((getPcWechatAmount() == null) ? 0 : getPcWechatAmount().hashCode());
        result = prime * result + ((getPcAliAmount() == null) ? 0 : getPcAliAmount().hashCode());
        return result;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", pcId=").append(pcId);
        sb.append(", pcWechatAmount=").append(pcWechatAmount);
        sb.append(", pcAliAmount=").append(pcAliAmount);
        sb.append(", serialVersionUID=").append(serialVersionUID);
        sb.append("]");
        return sb.toString();
    }
}